package com.hxzy.shop.utils;

import cn.hutool.core.date.DateUtil;
import org.springframework.http.HttpHeaders;

/**
 * @Author wxy
 * @Date 2021/5/6 19:41
 * @Version 1.0
 */
public final class HttpHeadUtils {

    public static HttpHeaders header() {
        HttpHeaders headers = new HttpHeaders();
        headers.add("Cache-Control", "no-cache, no-store, must-revalidate");
        headers.add("Content-Disposition", "attachment; filename=Verification Code");
        headers.add("Pragma", "no-cache");
        headers.add("Expires", "0");
        headers.add("Last-Modified", DateUtil.now());
        headers.add("ETag", String.valueOf(System.currentTimeMillis()));
        return headers;
    }
}
